#!/usr/bin/env python
# -*- coding: utf-8 -*- #
from utils import *
from dataset import *

path = './data/njdt_20210108_000105_559_3.rda'
path1 = './data/njdt_20210108_000113_625_2.rda'
path2 = './data/njdt_20210108_000120_939_1.rda'

if __name__ == '__main__':
    #sinc数据集
    scal = 10
    n = 200
    #x, y, verbose = sinc_function(scal)        # 满足sinc函数数据集

    #x, y, verbose = get_correlated_dataset(n)    # 满足高斯分布的数据集

    x, y, verbose = read_data_file(path=path1)    # 现实电厂数据集

    compress_x, compress_y = compress_data_plot(x, y, scale=scal, flag='sdt', verbose=verbose)  #进行压缩操作

    gamma, optimal = data_model_predict(compress_x, compress_y, verbose)   # 模型训练和预测阶段